//
//  MYNewsShopDetailsCategoryCollCellCollectionViewCell.swift
//  MuYing
//
//  Created by tbb on 2020/3/6.
//  Copyright © 2020 TBB. All rights reserved.
//

import UIKit

class MYNewsShopDetailsCategoryCollCell: UICollectionViewCell {
    
    var standardModel:MYNewsShopDetailsStandardModel? {
        didSet {
            self.titleLb.text = self.standardModel?.standardName;
            
        
            guard let isCrrent = self.standardModel?.isCurrent else {
                return;
            }
            
            if isCrrent {
                self.titleLb.textColor = UIColorFromHex(rgbValue: 0xF88282);
                self.contentView.layer.borderColor = UIColorFromHex(rgbValue: 0xF88282).cgColor;
            }else{
                self.titleLb.textColor = UIColorFromHex(rgbValue: 0x656565);
                self.contentView.layer.borderColor = UIColor.clear.cgColor;
            }
        }
    }
    

    @IBOutlet weak var titleLb: UILabel!
    override func awakeFromNib() {
        super.awakeFromNib()
        self.backgroundColor = UIColor.clear;
        self.contentView.backgroundColor = UIColorFromHexAndAlpha(rgbValue: 0x000000, alpha: 0.03)
        self.contentView.layer.borderWidth = 1;
        self.contentView.layer.cornerRadius = 4.0;
        self.contentView.clipsToBounds = true;
        
    }

}
